﻿//Created by Action Script Viewer - http://www.buraks.com/asv
package net.wooga.pets.views.components {
    import reprise.ui.*;
    import flash.events.*;
    import reprise.commands.*;

    public class VisitFriendTransition extends UIComponent {

        private var _animationDisplay:UIComponent;

        override public function show(... _args):void{
            super.show();
            addCSSClass("show");
            this._animationDisplay = addComponent("animationDisplay");
        }
        override public function hide(... _args):void{
            var _local2:TimerCommand = new TimerCommand(500);
            _local2.addEventListener(Event.COMPLETE, this.delay_complete);
            _local2.execute();
        }
        private function delay_complete(_arg1:Event):void{
            var _local2:TimerCommand = TimerCommand(_arg1.target);
            _local2.removeEventListener(Event.COMPLETE, this.delay_complete);
            var _local3:TimerCommand = new TimerCommand(400);
            _local3.addEventListener(Event.COMPLETE, this.fadeOut_complete);
            _local3.execute();
            removeCSSClass("show");
        }
        private function fadeOut_complete(_arg1:Event):void{
            var _local2:TimerCommand = TimerCommand(_arg1.target);
            _local2.removeEventListener(Event.COMPLETE, this.delay_complete);
            this._animationDisplay.remove();
            this._animationDisplay = null;
            super.hide();
        }
        override protected function initialize():void{
            cssID = "visitFriendTransition";
            super.initialize();
        }
        override protected function createChildren():void{
            super.createChildren();
        }

    }
}//package net.wooga.pets.views.components 
